package com.example.leetcode.graph;

import com.example.leetcode.graph.common.GraphUtils;

class Solution990 {
    public boolean equationsPossible(String[] equations) {
        return GraphUtils.equationsPossible(equations);
    }
}

public class leetcode990 {
    public static void main(String[] args) {
        Solution990 solution990 = new Solution990();
        String[] equations = {"a==b", "b!=a"};
        String[] equations1 = {"b==a", "a==b"};
        String[] equations2 = {"a==b", "b==c", "a==c"};
        String[] equations3 = {"a==b", "b!=c", "c==a"};
        String[] equations4 = {"c==c", "b==d", "x!=z"};
        System.out.println(solution990.equationsPossible(equations));
        System.out.println(solution990.equationsPossible(equations1));
        System.out.println(solution990.equationsPossible(equations2));
        System.out.println(solution990.equationsPossible(equations3));
        System.out.println(solution990.equationsPossible(equations4));
    }
}
